package com.systemframework.sys.service.impl;


import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.systemframework.sys.dto.request.SysDeptRequestDTO;
import com.systemframework.sys.dto.response.SysDeptResponseDTO;
import com.systemframework.sys.entity.SysDept;
import com.systemframework.sys.mapper.SysDeptMapper;
import com.systemframework.sys.service.SysDeptService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @author summer
 * @date 2023-03-21 9:29
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class SysDeptServiceImpl extends ServiceImpl<SysDeptMapper, SysDept> implements SysDeptService {


    @Override
    public List<SysDeptResponseDTO> childrenDeptLists(SysDeptRequestDTO sysDeptRequestDTO) {
        return this.baseMapper.childrenDeptLists(sysDeptRequestDTO.getName());
    }
}
